<template>
	<view>
		<picker @change="bindPickerChange" :value="enumId" :range="array" range-key="meaning">
			<view class="uni-input">{{array[enumId].meaning}}</view>
		</picker>
	</view>
</template>

<script>
	export default {
		name: "mypick",
		props: [
			"array"
		],
		data() {
			return {
				enumId: 0,
			};
		},
		methods: {
			bindPickerChange: function(e) {
				this.enumId = e.target.value
				this.$emit("getChild", this.array[this.enumId].enumValue)
			}
		}
	}
</script>

<style>

</style>
